﻿using System;
using System.Collections.Generic;

using System.Windows.Controls;
using Microsoft.Windows.Controls;

namespace Might.UIControls.PackageBrowser {

    /// <summary>
    /// Interface for ModelTreeView
    /// </summary>
    public interface IPackageBrowserView {

        /// <summary>
        /// Occurs when some item from model tree is double clicked
        /// </summary>
        event EventHandler ModelTreeDoubleClick;

        /// <summary>
        /// Gets the selected tree item data.
        /// </summary>
        /// <value>The selected item data.</value>
        object SelectedItemData { get; }

        /// <summary>
        /// Adds the new root of the tree.
        /// </summary>
        /// <param name="root">The root.</param>
        void AddTreeRoot( TreeViewItem root );

        /// <summary>
        /// Adds the tree item.
        /// </summary>
        /// <param name="item">The item.</param>
        /// <param name="toItem">To item.</param>
        void AddTreeItem( TreeViewItem item , TreeViewItem toItem );

        /// <summary>
        /// Updates the icon on the tree view node.
        /// </summary>
        /// <param name="item">The tree view node which should updated his icon.</param>
        void UpdateIcon( TreeViewItem item );

        /// <summary>
        /// Clears the tree.
        /// </summary>
        void Clear(); 
    
    }

}